<template>
<div class="singleData">
    <h3>{{ singleData.title }}</h3>
    <p>{{ singleData.content }}</p>
    <span class="tags" v-for="tag in singleData.tags" :key="tag">{{ tag }}</span>
  </div>
</template>

<script setup>
import getSingle from '../api/getSingle'
const props = defineProps({
    id:String
})
const {singleData} = getSingle(props.id)
console.log('这是0'+ singleData.value)

</script>

<style scoped>
.singleData{
  margin: 0 auto;
  text-align: center;
  width: 100%;
  height: 100%;
  background-color:beige;
}
</style>